home *** CD-ROM | disk | FTP | other *** search
/ Amiga Format CD 49 / Amiga Format CD49 (2000-01-17)(Future Publishing)(GB)(Track 1 of 3)[!][issue 2000-02].iso / -serious- / graphics / amicad / install english < prev    next >
Text File  |  1999-12-06  |  12KB  |  362 lines

  1. ;----------------------------------------------------------------------------
  2. ; Installation script for AmiCAD
  3. ;
  4. ; $VER: AmiCAD-Install 1.3 (06.05.98)
  5. ;
  6. ; (C)1997-1998 R.Florac
  7.  
  8. ;****************************************************************************
  9. ; Creation of the AmiCAD drawer *********************************************
  10. ;****************************************************************************
  11. (set #AmiCADdestdir-help "A directory named AmiCAD will be created, if it doesn't allready exists, at the place you'll choose")
  12.  
  13. (set #destination
  14.     (expandpath
  15.     (askdir
  16.         (prompt "Where do you want to install the AmiCAD drawer?")
  17.         (help #AmiCADdestdir-help)
  18.         (default @default-dest)
  19.         (disk)
  20.     )
  21.     )
  22. )
  23.  
  24. (set @default-dest (tackon #destination "AmiCAD"))
  25.  
  26. (if (= 0 (askbool
  27.     (prompt "Destination directory for AmiCAD\nwill be "@default-dest)
  28.     (choices "Continue" "Stop")
  29.     (help "If the specified directory doesn't agree, choose 'Stop': you'll have to restart this installer script and choose another directory for destination.")
  30.     ))
  31.     (exit (quiet))
  32. )
  33.  
  34. (if (= (exists @default-dest (noreq)) 0) (makedir @default-dest (infos)))
  35. (makedir (tackon @default-dest "Library"))
  36. (makedir (tackon @default-dest "Sheets") (infos))
  37. (makedir (tackon @default-dest "Clips"))
  38. (makedir (tackon @default-dest "ARexx"))
  39. (makedir (tackon @default-dest "ToolBars"))
  40.  
  41. ;****************************************************************************
  42. ; Copy of the AmiCAD files **************************************************
  43. ;****************************************************************************
  44. (copyfiles
  45.     (source "")
  46.     (dest @default-dest)
  47.     (pattern "AmiCAD#?")
  48.     (prompt "Choose the files you want to copy")
  49.     (help (cat "Select the files you want to copy, only the marked files will be copied.\nAmiCAD is the program file.\nAmiCAD.keys is the file where you are stored the definitions of macros keys.\n"
  50.     "AmiCAD.prefs is the file where are stored the preferences.\nAmiCAD.palette is a preferences file which contains only a black screen background palette (load it with the Preferences/configuration menu to try it)."))
  51.     (confirm)
  52.     (infos)
  53. )
  54.  
  55. (delete (tackon @default-dest "AmiCAD.prefs"))
  56. (copyfiles
  57.     (source "prefs.english")
  58.     (dest @default-dest)
  59. )
  60. (rename (tackon @default-dest "prefs.english") (tackon @default-dest "AmiCAD.prefs"))
  61.  
  62. ;****************************************************************************
  63. ; Copy of the AmiCAD libraries (symbols files) ******************************
  64. ;****************************************************************************
  65. (copyfiles
  66.     (source "Bibliothèques")
  67.     (dest (tackon @default-dest "Library"))
  68.     (pattern "#?")
  69.     (prompt "Choose the symbols files to copy\nThe format of this files have changed in version 1.2, so replace your old library files. Some files has been updated.")
  70.     (help "Select the files you want to copy, they are symbols files, AmiCAD use them to draw schematics.\nThe library Symboles_électriques contains a new symbol.")
  71.     (confirm)
  72.     (infos)
  73. )
  74.  
  75. ;****************************************************************************
  76. ; Copy of the AmiCAD clips **************************************************
  77. ;****************************************************************************
  78. (copyfiles
  79.     (source "Clips_english")
  80.     (dest (tackon @default-dest "Clips"))
  81.     (pattern "#?")
  82.     (prompt "Choose the clip files to copy")
  83.     (help "Select the files you want to copy, they are clip files, defined with AmiCAD.\nThey can be used to draw some current symbols not yet defined in the libraries.\nYou shall be able to define your own clips with AmiCAD.")
  84.     (confirm)
  85.     (infos)
  86. )
  87.  
  88. ;****************************************************************************
  89. ; Copy of the AmiCAD ARexx scripts ******************************************
  90. ;****************************************************************************
  91. (copyfiles
  92.     (source "ARexx_english")
  93.     (dest (tackon @default-dest "ARexx"))
  94.     (pattern "#?")
  95.     (prompt "Choose the ARexx scripts you want to copy\n")
  96.     (help "Select the files you want to copy.\nThe contents of this files are macro-commands, they can be used with AmiCAD. Many old scripts have been enhanced and some new scripts are presents.\nFrench ARexx scripts are often updated but not translated")
  97.     (confirm)
  98.     (infos)
  99. )
  100.  
  101. ;****************************************************************************
  102. ; Copy of the AmiCAD sheet files ********************************************
  103. ;****************************************************************************
  104. (copyfiles
  105.     (source "Schémas")
  106.     (dest (tackon @default-dest "Sheets"))
  107.     (pattern "#?")
  108.     (prompt "Choose the sheets files you want to copy\n")
  109.     (help "Select the files you want to copy, they are examples files obtained with AmiCAD.")
  110.     (confirm)
  111.     (infos)
  112. )
  113.  
  114. ;****************************************************************************
  115. ; Setting the tooltypes of the AmiCAD icon **********************************
  116. ;****************************************************************************
  117. (tooltype
  118.     (prompt "Setting AmiCAD LIBS Tooltypes")
  119.     (dest (tackon @default-dest "AmiCAD"))
  120.     (settooltype "LIBS" (tackon @default-dest "library"))
  121. )
  122.  
  123. (tooltype
  124.     (prompt "Setting AmiCAD CLIPS Tooltype")
  125.     (dest (tackon @default-dest "AmiCAD"))
  126.     (settooltype "CLIPS" (tackon @default-dest "Clips"))
  127. )
  128.  
  129. (tooltype
  130.     (prompt "Setting AmiCAD HELPFILE Tooltype")
  131.     (dest (tackon @default-dest "AmiCAD"))
  132.     (settooltype "HELPFILE" (tackon @default-dest "AmiCAD.guide"))
  133. )
  134.  
  135. (set msg_welcome "IF(OBJECTS(-1)==0,LOAD(\"Sheets/Logo\"),0):MESSAGE(\"Welcome with AmiCAD\"+CHR(10)+\"the electronics editor\"+CHR(10)+\"for Amiga computer.\")")
  136. (tooltype
  137.     (prompt "Set AmiCAD Macro Tooltypes")
  138.     (dest (tackon @default-dest "AmiCAD"))
  139.     (settooltype "MACRO" msg_welcome)
  140. )
  141.  
  142. ;****************************************************************************
  143. ; Copy of the AmiCAD.guide file *********************************************
  144. ;****************************************************************************
  145. (set catalogue 1)
  146. (if (= @language "français") (set catalogue 0))
  147.  
  148. (set catalogues
  149.     (askchoice
  150.         (prompt "Select the guide you want to install")
  151.         (help "The english guide is not yet finished. Large parts of it are allways in french language.")
  152.         (choices "Français" "English")
  153.         (default catalogue)
  154.     )
  155. )
  156.  
  157. (if (= catalogues 0)
  158.     (copyfiles
  159.     (prompt "Copying the french guide")
  160.     (source ("docs/français"))
  161.     (dest (@default-dest))
  162.     (all)
  163.     )
  164. )
  165.  
  166. (if (= catalogues 1)
  167.     (copyfiles
  168.     (prompt "Copying the english guide")
  169.     (source ("docs/english"))
  170.     (dest (@default-dest))
  171.     (all)
  172.     )
  173. )
  174.  
  175. ;****************************************************************************
  176. ; Copy of the AmiCAD catalogs ***********************************************
  177. ;****************************************************************************
  178. (set catalogue 32)
  179. (if (= @language "français") (set catalogue 1))
  180. (if (= @language "deutsch") (set catalogue 2))
  181. (if (= @language "ÃeÓtina") (set catalogue 4))
  182. (if (= @language "español") (set catalogue 8))
  183. (if (= @language "italiano") (set catalogue 16))
  184. (if (= @language "slovensko") (set catalogue 64))
  185.  
  186. (set catalogues
  187.     (askoptions
  188.         (prompt "Select the catalog you want to install")
  189.         (help "The catalog of your country is the one you have to copy.\nThe english catalogs are for library files.\nSome library catalogs have been written (deutsch and english languages)")
  190.         (choices "Français" "Deutsch" "Czech" "Español" "Italiano" "English" "Slovensko")
  191.         (default catalogue)
  192.     )
  193. )
  194.  
  195. (if (= (BITAND catalogues 1) 1)
  196.     (   (makedir (tackon @default-dest "Catalogs"))
  197.     (copyfiles
  198.         (prompt "Copying the french catalog")
  199.         (source ("Catalogs/français"))
  200.         (dest   (tackon @default-dest "catalogs/français"))
  201.         (all)
  202.     )
  203.     )
  204. )
  205.  
  206. (if (= (BITAND catalogues 2) 2)
  207.     (   (makedir (tackon @default-dest "Catalogs"))
  208.     (copyfiles
  209.         (prompt "Copying the deutsch catalog")
  210.         (source ("Catalogs/deutsch"))
  211.         (dest   (tackon @default-dest "catalogs/deutsch"))
  212.         (all)
  213.     )
  214.     )
  215. )
  216.  
  217. (if (= (BITAND catalogues 4) 4)
  218.     (   (makedir (tackon @default-dest "Catalogs"))
  219.     (copyfiles
  220.         (prompt "Copying the czech catalog")
  221.         (source ("Catalogs/ÃeÓtina"))
  222.         (dest   (tackon @default-dest "catalogs/ÃeÓtina"))
  223.         (all)
  224.     )
  225.     )
  226. )
  227.  
  228. (if (= (BITAND catalogues 8) 8)
  229.     (   (makedir (tackon @default-dest "Catalogs"))
  230.     (copyfiles
  231.         (prompt "Copying the spanish catalog")
  232.         (source ("Catalogs/español"))
  233.         (dest   (tackon @default-dest "catalogs/español"))
  234.         (all)
  235.     )
  236.     )
  237. )
  238.  
  239. (if (= (BITAND catalogues 16) 16)
  240.     (   (makedir (tackon @default-dest "Catalogs"))
  241.     (copyfiles
  242.         (prompt "Copying the italian catalogs")
  243.         (source ("Catalogs/italiano"))
  244.         (dest   (tackon @default-dest "catalogs/italiano"))
  245.         (all)
  246.     )
  247.     )
  248. )
  249.  
  250. (if (= (BITAND catalogues 32) 32)
  251.     (   (makedir (tackon @default-dest "Catalogs"))
  252.     (copyfiles
  253.         (prompt "Copying the english catalogs")
  254.         (source ("Catalogs/english"))
  255.         (dest   (tackon @default-dest "catalogs/english"))
  256.         (all)
  257.     )
  258.     )
  259. )
  260.  
  261. (if (= (BITAND catalogues 64) 64)
  262.     (   (makedir (tackon @default-dest "Catalogs"))
  263.     (copyfiles
  264.         (prompt "Copying the slovenian catalogs")
  265.         (source ("Catalogs/slovensko"))
  266.         (dest   (tackon @default-dest "catalogs/slovensko"))
  267.         (all)
  268.     )
  269.     )
  270. )
  271.  
  272. ;****************************************************************************
  273. ; Copy of the catalogs sources **********************************************
  274. ;****************************************************************************
  275. (set catalogues
  276.     (askbool
  277.         (prompt "Do you want to copy the catalog sources files?")
  278.         (help "The sources files of the catalog are only needed if you want to create a catalog file for a new country (not yet done).")
  279.         (default 0)
  280.     )
  281. )
  282.  
  283.  
  284. (if (= catalogues 1)
  285.     (   (set sources
  286.         (askoptions
  287.         (prompt "Select the catalogs sources you want to install")
  288.         (help "The sources files of the catalog are only needed if you want to create a catalog file for a new country (not yet done).")
  289.         (choices "French" "Deutsch" "Czech" "Italiano" "english")
  290.         (default catalogue)
  291.         )
  292.     )
  293.     (if (= (BITAND sources 1) 1)
  294.         (   (makedir (tackon @default-dest "Catalogs"))
  295.         (copyfiles
  296.             (prompt "Copying the french source catalog")
  297.             (source ("Catalogs"))
  298.             (pattern ("#?.(français.ct|cd)"))
  299.             (dest   (tackon @default-dest "catalogs"))
  300.             (files)
  301.         )
  302.         )
  303.     )
  304.     (if (= (BITAND sources 2) 2)
  305.         (   (makedir (tackon @default-dest "Catalogs"))
  306.         (copyfiles
  307.             (prompt "Copying the deutsch source catalog")
  308.             (source ("Catalogs"))
  309.             (pattern ("#?.(deutsch.ct|cd)"))
  310.             (dest   (tackon @default-dest "catalogs"))
  311.             (files)
  312.         )
  313.         )
  314.     )
  315.     (if (= (BITAND sources 4) 4)
  316.         (   (makedir (tackon @default-dest "Catalogs"))
  317.         (copyfiles
  318.             (prompt "Copying the czech source catalog")
  319.             (source ("Catalogs"))
  320.             (pattern ("#?.(ÃeÓtina.ct|cd)"))
  321.             (dest   (tackon @default-dest "catalogs"))
  322.             (files)
  323.         )
  324.         )
  325.     )
  326.     (if (= (BITAND sources 8) 8)
  327.         (   (makedir (tackon @default-dest "Catalogs"))
  328.         (copyfiles
  329.             (prompt "Copying the italian source catalog")
  330.             (source ("Catalogs"))
  331.             (pattern ("#?.(italiano.ct|cd)"))
  332.             (dest   (tackon @default-dest "catalogs"))
  333.             (files)
  334.         )
  335.         )
  336.     )
  337.     (if (= (BITAND sources 16) 16)
  338.         (   (makedir (tackon @default-dest "Catalogs"))
  339.         (copyfiles
  340.             (prompt "Copying the english source catalogs")
  341.             (source ("Catalogs"))
  342.             (pattern ("#?.(english.ct|cd)"))
  343.             (dest   (tackon @default-dest "catalogs"))
  344.             (files)
  345.         )
  346.         )
  347.     )
  348.     )
  349. )
  350.  
  351. ;****************************************************************************
  352. ; Copy of toolbars **********************************************************
  353. ;****************************************************************************
  354. (copyfiles
  355.     (prompt "Copying toolbars")
  356.     (source ("barres"))
  357.     (dest (tackon @default-dest "ToolBars"))
  358.     (all)
  359. )
  360.  
  361. (exit)
  362.